package com.sixth.system.service.impl;/**
 *  @author  633yh
 *  @version 1.0
 */

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.sixth.core.entity.Banner;
import com.sixth.core.vo.R;
import com.sixth.system.mapper.BannerMapper;
import com.sixth.system.service.BannerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author     ：Stu YH
 * @date       ：Created in 2024/8/23 14:17
 * @description：
 * @modified By：
 * @version:     
 */
@Service
public class BannerServiceImpl implements BannerService {
   @Autowired
   private BannerMapper bannerMapper;

   @Override
   public R<List<Banner>> getBanner() {
      QueryWrapper<Banner> wrapper = new QueryWrapper<>();
      wrapper.eq("position",1);
      return R.ok(bannerMapper.selectList(wrapper));
   }
}
